/*
 * ItemEvolutionResource.h
 *
 *  Created on: 2013. 10. 8.
 *      Author: mega@gamevil.com
 */

#ifndef ITEMEVOLUTIONRESOURCE_H_
#define ITEMEVOLUTIONRESOURCE_H_

#include <map>

namespace ProjectZ { namespace NResource {

class ItemEvolutionResource
{
public:
	struct Flyweight
	{
		int _STEP;
		int _RATE;
	};

public:
	ItemEvolutionResource();
	virtual ~ItemEvolutionResource();


	bool LoadResource();
	Flyweight * GetFly(int step);

	int		GetEvolveEffect(User * pUser);
	int		GetEvolveNeedPoint(int evolveStep);
	int		GetEvolveAddPoint(User * pUser, int itemLevel);
	int		GetEvolveMaxStep(User * pUser, int itemLevel);

private:
	typedef std::map<int, Flyweight *>	EVOLUTIONTREE;
	EVOLUTIONTREE	clsFlyTree;
};

} /*NResource*/ } /* namespace ProjectZ */


#endif /* ITEMEVOLUTIONRESOURCE_H_ */
